6f17a91f0cbcf2637610f1dc2abf4eced8e8ac89,core/generator/source/jetbrains/mps/generator/impl/reference/ReferenceInfo.java,ReferenceInfo,checkResolvedTarget,#AbstractTemplateGenerator#SNode#,111
Before Change
if (SModelStereotype.isGeneratorModel(referentNodeModel)) {
// references to template nodes are not acceptable
generator.getLogger().error(myOutputSourceNode,
"bad reference, cannot refer to a generator model: " + SNodeUtil.getDebugText(outputTargetNode) + " for role '" + myReferenceRole + "' in " +
SNodeUtil.getDebugText(myOutputSourceNode),
getErrorDescriptions());
return false;
}
After Change
if (referentNodeModel != myOutputSourceNode.getModel()) {
if (SModelStereotype.isGeneratorModel(referentNodeModel)) {
// references to template nodes are not acceptable
String msg = "bad reference, cannot refer to a generator model: %s for role '%s' in %s";
generator.getLogger().error(myOutputSourceNode.getReference(), String.format(msg,
SNodeUtil.getDebugText(outputTargetNode), myReferenceRole, SNodeUtil.getDebugText(myOutputSourceNode)),
getErrorDescriptions());
return false;
}